// uno.config.ts
import presetRemToPx from "@unocss/preset-rem-to-px";
import transformerDirectives from "@unocss/transformer-directives";
import transformerVariantGroup from "@unocss/transformer-variant-group";
import { defineConfig, presetAttributify, presetUno, presetWebFonts } from "unocss";

import { borderColorRules, gradientColorsRules, unoColorsRules, borderRadiusRules, webFontsOptions } from "./uno.vars";

export default defineConfig({
	//自定义组合
	shortcuts: {
		"auth-logo": "w-[96px] h-[26px]",
		"flex-col-1": "flex flex-col flex-1",
		"flex-center": "flex items-center justify-center",
		"flex-between": "flex items-center justify-between"
	},
	//自定义规则
	rules: [...unoColorsRules, ...gradientColorsRules, ...borderRadiusRules, ...borderColorRules],
	theme: {
		boxShadow: {
			normal: "0px 5px 30px 0px rgba(0, 0, 0, 0.1)"
		}
	},
	presets: [
		presetUno(),
		presetAttributify(),
		presetRemToPx(),
		presetWebFonts({
			...webFontsOptions
		})
	],
	transformers: [transformerDirectives(), transformerVariantGroup()]
});
